package com.linkwechat.wecom.controller;

import com.linkwechat.common.utils.ResultUtil;
import com.linkwechat.common.vo.CommonRsp;
import com.linkwechat.wecom.service.QwService;
import com.linkwechat.common.vo.qw.AppInfoVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @Author 王君平
 * @Date 2024/6/7 14:30
 * @Description
 */
@Slf4j
@Api(value = "企业微信微信-sys-wecom", tags = {"企业微信-wecom"})
@RequestMapping("/qywx/sys")
@Controller
public class QwController {

    @Autowired
    private QwService qwService;
    /**
     * 自建应用的信息
     */
    @ApiOperation(value = "自建应用的信息",hidden = false)
    @RequestMapping(value = "/appInfo", method = RequestMethod.GET)
    @ResponseBody
    public CommonRsp<AppInfoVO> currentAppInfo() {
        AppInfoVO vo = qwService.appInfo();
        return ResultUtil.success(vo);
    }


}
